local skel = fk.CreateSkill{
  name = "ofl_heg__hongju",
  tags = { Skill.Limited }
}
local H = require "packages/hegemony/util"
---@type ActiveSkillSpec
local hongju = {
  anim_type = "offensive",
  target_num = 1,
  card_filter = Util.FalseFunc,
  target_filter = function(self, to_select, selected)
    return #selected == 0 and to_select ~= Self.id
  end,
  can_use = function(self, player)
    return player:hasShownSkill(self) and player:usedSkillTimes(self.name, Player.HistoryGame) == 0
  end,
  on_use = function(self, room, effect)
    local player = effect.from
    local to = effect.tos[1]
    room:doIndicate(player.id, {to.id})
    local command = H.startCommand(player, self.name, 4)
    for _, p in ipairs(room:getOtherPlayers(to)) do
      if p ~= player then
        local isDoCommand = H.doCommand(p, self.name, command, player)
        if not isDoCommand then
          room:setPlayerMark(p, "@@lure_tiger-turn", 1)
          room:setPlayerMark(p, MarkEnum.PlayerRemoved .. "-turn", 1)
          room:handleAddLoseSkills(p, "#lure_tiger_hp|#lure_tiger_prohibit", nil, false, true) -- global...
          room.logic:trigger("fk.RemoveStateChanged", p, nil)
        end
      else
        H.doCommand(p, self.name, command, player, true)
      end
    end
  end,
}
skel:addEffect("active", hongju)
return skel